/* *****************************************************************************
 * Copyright (c) Huawei Technologies Co., Ltd. 2015-2022. All rights reserved.
 ******************************************************************************
 File Name      : service_type.h
 Description    : xxxxxxxx
 History        :
 1.date         : 2015/3/9
   Modification : Creat file

***************************************************************************** */
#ifndef SERVICE_TYPE_PUB_H
#define SERVICE_TYPE_PUB_H

#ifdef __cplusplus
#if __cplusplus
extern "C" {
#endif
#endif /* __cplusplus */

/* ******** Macro Definition ******** */
#define QU_FLUSH_SERVICETYPE_RSVD 0X1F
/* *
 * Enum name  :    service_type_e
 * @brief
 * Description: is used to configure and query qpc entries.
 */
typedef enum {
    SERVICE_TYPE_L2NIC = 1,
    SERVICE_TYPE_ROCE = 2,
    SERVICE_TYPE_CQ = 3,
    SERVICE_TYPE_ROCEAA = 4,
    SERVICE_TYPE_TOE,
    SERVICE_TYPE_FCOE,
    SERVICE_TYPE_DSWARE,
    SERVICE_TYPE_FC,
    SERVICE_TYPE_MIGRATE,
    SERVICE_TYPE_REMOTE_DB = 15,
    SERVICE_TYPE_RSVD = 15,
    SERVICE_TYPE_ROCE_NOFAA = 16,
    SERVICE_TYPE_ISN = 17,
    SERVICE_TYPE_VROCE = 26,
} service_type_e;

/* *
 * Enum name  :    release_pro_type_e
 * @brief          xxxxxxxx
 * Description: is used to indicate the protocol type when the thread is released. The protocol type must be aligned
 * with the msg_pro_type and pkt_pro_type numbers. (The isch allocates threads based on the pro_type provided by the
 * iq.)
 */
typedef enum {
    RELEASE_PRO_TYPE_L2NIC = 0,
    RELEASE_PRO_TYPE_GSO = 1,
    RELEASE_PRO_TYPE_ROCE = 2,
    RELEASE_PRO_TYPE_IOE = 9,
    RELEASE_PRO_TYPE_TOE = 10,
    RELEASE_PRO_TYPE_OVS_VXLAN = 10,
    RELEASE_PRO_TYPE_FC_PARENT = 11,
    RELEASE_PRO_TYPE_FC_CHILD = 11,
    RELEASE_PRO_TYPE_SACL = 12,
    RELEASE_PRO_TYPE_OVS = 13,
    RELEASE_PRO_TYPE_CMDQ = 14,
    RELEASE_PRO_TYPE_RSVD = 15,
} release_pro_type_e;

/* *
 * Enum name  :    msg_pro_type_e
 * @brief          xxxxxxxx
 * Description: Indicates the protocol type (recommended for the same protocol type) and the pointer to the entry
 * function when the thread is released in the msg process. Roce needs to reserve protype for subtype.
 */
typedef enum {
    MSG_PRO_TYPE_L2NIC = 0,
    MSG_PRO_TYPE_ROCE_ARMCQ = 0,
    MSG_PRO_TYPE_GSO = 1,
    MSG_PRO_TYPE_ROCE = 2,
    MSG_PRO_TYPE_ROCE_RC_SEND = 3,
    MSG_PRO_TYPE_ROCE_RC_SEND_IMME = 4,
    MSG_PRO_TYPE_ROCE_RC_WRITE = 5,
    MSG_PRO_TYPE_ROCE_RC_WRITE_IMME = 6,
    MSG_PRO_TYPE_ROCE_RC_READ = 7,
    MSG_PRO_TYPE_ROCE_RC_ATOMIC_CMPSWP = 8,
    MSG_PRO_TYPE_ROCE_RC_ATOMIC_FETCHADD = 9,
    MSG_PRO_TYPE_IWARP = 9,
    MSG_PRO_TYPE_TOE = 10,
    MSG_PRO_TYPE_FCOE_PARENT = 10,
    MSG_PRO_TYPE_FCOE_CHILD = 11,
    MSG_PRO_TYPE_ROCE_REMOTE_DB = 11,
    MSG_PRO_TYPE_SACL = 12,
    MSG_PRO_TYPE_OTHER_DB = 12,
    MSG_PRO_TYPE_OVS = 13,
    MSG_PRO_TYPE_VSW_TIMER = 13,
    MSG_PRO_TYPE_ROCE_REMOTE = 14,
    MSG_PRO_TYPE_IWARP_REMOTE = 14,
    MSG_PRO_TYPE_FC_TASK_EVENT = 14,
    MSG_PRO_TYPE_TIMER = 15,
    MSG_PRO_TYPE_RSVD = 15,
} msg_pro_type_e;

/* *
 * Enum name  :    pkt_pro_type_e
 * @brief          xxxxxxxx
 * Description: Indicate the protocol type and the pointer to the entry function when the thread is released in the PKT
 * process.
 */
typedef enum {
    PKT_PRO_TYPE_L2NIC = 0,
    PKT_PRO_TYPE_GSO = 1,
    PKT_PRO_TYPE_ROCE = 2,
    PKT_PRO_TYPE_ROCE_RC_SEND_ONLY = 3,
    PKT_PRO_TYPE_ROCE_RC_WRITE_ONLY = 4,
    PKT_PRO_TYPE_ROCE_SEND_NOMAL = 5,
    PKT_PRO_TYPE_ROCE_WRITE_NOMAL = 6,
    PKT_PRO_TYPE_ROCE_READ = 7,
    PKT_PRO_TYPE_ROCE_READ_RSP = 8,
    PKT_PRO_TYPE_ROCE_ATOMIC_ACK = 8,
    PKT_PRO_TYPE_ROCE_ACK = 9,
    PKT_PRO_TYPE_IWARP = 9,
    PKT_PRO_TYPE_TOE = 10,
    PKT_PRO_TYPE_FCOE = 11,
    PKT_PRO_TYPE_SACL = 12,
    PKT_PRO_TYPE_OVS = 13,
    PKT_PRO_TYPE_CMDQ = 14,
    PKT_PRO_TYPE_RSVD = 15,
} pkt_pro_type_e;


#ifdef __cplusplus
#if __cplusplus
}
#endif
#endif /* __cplusplus */


#endif /* SERVICE_TYPE_PUB_H */
